<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>DTL标签练习</title>
    <style type="text/css">
        .raw1 {
            color: #ffa1a8;
        }

        .raw2 {
            color: #a8ff2c;
        }
    </style>
</head>
<body>
<h3>用户列表</h3>
{% for user in list_users %}
    <p class="{% cycle 'raw1' 'raw2' %}">
        <br/>
        {#        <p>{{ forloop.counter }}用户的信息</p>#}
        {% for key,value in user.items %}
            {{ key }}:{{ value }}
        {% endfor %}
        {% empty %}
        <p>暂无用户信息</p>
    </p>
{% endfor %}

     {% comment %}
      URL
     {% endcomment %}
    <br/>
    <a href="{% url 'index' %}">首页</a>

    {% load static %}
    <img src="{% static 'python.jpg' %}" alt="python">
</body>
</html>
